package org.ycx.doc.dao.model;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

public class DocProjectVersionExample implements Serializable {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    private static final long serialVersionUID = 1L;

    public DocProjectVersionExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria implements Serializable {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andVerIdIsNull() {
            addCriterion("VER_ID is null");
            return (Criteria) this;
        }

        public Criteria andVerIdIsNotNull() {
            addCriterion("VER_ID is not null");
            return (Criteria) this;
        }

        public Criteria andVerIdEqualTo(Integer value) {
            addCriterion("VER_ID =", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdNotEqualTo(Integer value) {
            addCriterion("VER_ID <>", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdGreaterThan(Integer value) {
            addCriterion("VER_ID >", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("VER_ID >=", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdLessThan(Integer value) {
            addCriterion("VER_ID <", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdLessThanOrEqualTo(Integer value) {
            addCriterion("VER_ID <=", value, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdIn(List<Integer> values) {
            addCriterion("VER_ID in", values, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdNotIn(List<Integer> values) {
            addCriterion("VER_ID not in", values, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdBetween(Integer value1, Integer value2) {
            addCriterion("VER_ID between", value1, value2, "verId");
            return (Criteria) this;
        }

        public Criteria andVerIdNotBetween(Integer value1, Integer value2) {
            addCriterion("VER_ID not between", value1, value2, "verId");
            return (Criteria) this;
        }

        public Criteria andAppIdIsNull() {
            addCriterion("APP_ID is null");
            return (Criteria) this;
        }

        public Criteria andAppIdIsNotNull() {
            addCriterion("APP_ID is not null");
            return (Criteria) this;
        }

        public Criteria andAppIdEqualTo(Integer value) {
            addCriterion("APP_ID =", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdNotEqualTo(Integer value) {
            addCriterion("APP_ID <>", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdGreaterThan(Integer value) {
            addCriterion("APP_ID >", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("APP_ID >=", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdLessThan(Integer value) {
            addCriterion("APP_ID <", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdLessThanOrEqualTo(Integer value) {
            addCriterion("APP_ID <=", value, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdIn(List<Integer> values) {
            addCriterion("APP_ID in", values, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdNotIn(List<Integer> values) {
            addCriterion("APP_ID not in", values, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdBetween(Integer value1, Integer value2) {
            addCriterion("APP_ID between", value1, value2, "appId");
            return (Criteria) this;
        }

        public Criteria andAppIdNotBetween(Integer value1, Integer value2) {
            addCriterion("APP_ID not between", value1, value2, "appId");
            return (Criteria) this;
        }

        public Criteria andAppVersionIsNull() {
            addCriterion("APP_VERSION is null");
            return (Criteria) this;
        }

        public Criteria andAppVersionIsNotNull() {
            addCriterion("APP_VERSION is not null");
            return (Criteria) this;
        }

        public Criteria andAppVersionEqualTo(Integer value) {
            addCriterion("APP_VERSION =", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionNotEqualTo(Integer value) {
            addCriterion("APP_VERSION <>", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionGreaterThan(Integer value) {
            addCriterion("APP_VERSION >", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionGreaterThanOrEqualTo(Integer value) {
            addCriterion("APP_VERSION >=", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionLessThan(Integer value) {
            addCriterion("APP_VERSION <", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionLessThanOrEqualTo(Integer value) {
            addCriterion("APP_VERSION <=", value, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionIn(List<Integer> values) {
            addCriterion("APP_VERSION in", values, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionNotIn(List<Integer> values) {
            addCriterion("APP_VERSION not in", values, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionBetween(Integer value1, Integer value2) {
            addCriterion("APP_VERSION between", value1, value2, "appVersion");
            return (Criteria) this;
        }

        public Criteria andAppVersionNotBetween(Integer value1, Integer value2) {
            addCriterion("APP_VERSION not between", value1, value2, "appVersion");
            return (Criteria) this;
        }

        public Criteria andVerStartIsNull() {
            addCriterion("VER_START is null");
            return (Criteria) this;
        }

        public Criteria andVerStartIsNotNull() {
            addCriterion("VER_START is not null");
            return (Criteria) this;
        }

        public Criteria andVerStartEqualTo(Integer value) {
            addCriterion("VER_START =", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartNotEqualTo(Integer value) {
            addCriterion("VER_START <>", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartGreaterThan(Integer value) {
            addCriterion("VER_START >", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartGreaterThanOrEqualTo(Integer value) {
            addCriterion("VER_START >=", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartLessThan(Integer value) {
            addCriterion("VER_START <", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartLessThanOrEqualTo(Integer value) {
            addCriterion("VER_START <=", value, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartIn(List<Integer> values) {
            addCriterion("VER_START in", values, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartNotIn(List<Integer> values) {
            addCriterion("VER_START not in", values, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartBetween(Integer value1, Integer value2) {
            addCriterion("VER_START between", value1, value2, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerStartNotBetween(Integer value1, Integer value2) {
            addCriterion("VER_START not between", value1, value2, "verStart");
            return (Criteria) this;
        }

        public Criteria andVerEndIsNull() {
            addCriterion("VER_END is null");
            return (Criteria) this;
        }

        public Criteria andVerEndIsNotNull() {
            addCriterion("VER_END is not null");
            return (Criteria) this;
        }

        public Criteria andVerEndEqualTo(Integer value) {
            addCriterion("VER_END =", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndNotEqualTo(Integer value) {
            addCriterion("VER_END <>", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndGreaterThan(Integer value) {
            addCriterion("VER_END >", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndGreaterThanOrEqualTo(Integer value) {
            addCriterion("VER_END >=", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndLessThan(Integer value) {
            addCriterion("VER_END <", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndLessThanOrEqualTo(Integer value) {
            addCriterion("VER_END <=", value, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndIn(List<Integer> values) {
            addCriterion("VER_END in", values, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndNotIn(List<Integer> values) {
            addCriterion("VER_END not in", values, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndBetween(Integer value1, Integer value2) {
            addCriterion("VER_END between", value1, value2, "verEnd");
            return (Criteria) this;
        }

        public Criteria andVerEndNotBetween(Integer value1, Integer value2) {
            addCriterion("VER_END not between", value1, value2, "verEnd");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria implements Serializable {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion implements Serializable {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}